import React from 'react'
import './Item.css'
// 形参位置是在结构props
export default function Item({ todo: { id, todoName, isDone } }) {
  return (
    <li>
      <label>
        <input type="checkbox" checked={isDone} onChange={() => {}} />
        <span className={isDone ? 'active' : ''}>{todoName}</span>
      </label>
      <button className="btn btn-danger">删除</button>
    </li>
  )
}
